<!DOCTYPE html>
<html lang="en">
  <head>
    <title>Protocols  Reference</title>
    <link rel="stylesheet" type="text/css" href="css/jazzy.css" />
    <link rel="stylesheet" type="text/css" href="css/highlight.css" />
    <meta charset='utf-8'>
	<meta name="viewport" content="width=device-width, viewport-fit=cover, initial-scale=1.0" />
    <script src="js/jquery.min.js" defer></script>
    <script src="js/jazzy.js" defer></script>
    
  </head>
  <body>
    <a name="//apple_ref/swift/Section/Protocols" class="dashAnchor"></a>
    <a title="Protocols  Reference"></a>
    <header>
      <div class="content-wrapper">
        <p>
          <a href="index.html">PostgresClientKit Docs</a>
          <span class="no-mobile"> (100% documented)</span>
        </p>
    
        <p class="header-right">
          <a href="https://github.com/codewinsdotcom/PostgresClientKit">
            <img src="img/gh.png"/>
            <span class="no-mobile">View on GitHub</span>
          </a>
        </p>
    
      </div>
    </header>
    <div id="breadcrumbs-container">
      <div class="content-wrapper">
        <p id="breadcrumbs">
          <span class="no-mobile">
            <a href="index.html">PostgresClientKit Reference</a>
            <img id="carat" src="img/carat.png" />
          </span>
          Protocols  Reference
        </p>
      </div>
    </div>
    <div class="wrapper">
      <div class="article-wrapper">
        <article class="main-content">
          <section>
            <section class="section">
              <h1>Protocols</h1>
              <p>The following protocols are available globally.</p>

            </section>
            <section class="section task-group-section">
              <div class="task-group">
                <ul>
                  <li class="item">
                    <div>
                      <code>
                      <a name="/s:17PostgresClientKit18ConnectionDelegateP"></a>
                      <a name="//apple_ref/swift/Protocol/ConnectionDelegate" class="dashAnchor"></a>
                      <a class="token" href="#/s:17PostgresClientKit18ConnectionDelegateP">ConnectionDelegate</a>
                      </code>
                    </div>
                    <div class="height-container">
                      <div class="pointer-container"></div>
                      <section class="section">
                        <div class="pointer"></div>
                        <div class="abstract">
                          <p>A delegate for <code><a href="Classes/Connection.html">Connection</a></code> instances.</p>

                          <a href="Protocols/ConnectionDelegate.html" class="slightly-smaller">See more</a>
                        </div>
                        <div class="declaration">
                          <h4>Declaration</h4>
                          <div class="language">
                            <p class="aside-title">Swift</p>
                            <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">protocol</span> <span class="kt">ConnectionDelegate</span> <span class="p">:</span> <span class="kt">AnyObject</span></code></pre>

                          </div>
                        </div>
                      </section>
                    </div>
                  </li>
                  <li class="item">
                    <div>
                      <code>
                      <a name="/s:17PostgresClientKit10LogHandlerP"></a>
                      <a name="//apple_ref/swift/Protocol/LogHandler" class="dashAnchor"></a>
                      <a class="token" href="#/s:17PostgresClientKit10LogHandlerP">LogHandler</a>
                      </code>
                    </div>
                    <div class="height-container">
                      <div class="pointer-container"></div>
                      <section class="section">
                        <div class="pointer"></div>
                        <div class="abstract">
                          <p>An endpoint for log records.</p>

<p>If a <code><a href="Classes/Logger.html">Logger</a></code> determines a <code><a href="Structs/LogRecord.html">LogRecord</a></code> should be logged, that log record is dispatched to the
logger&rsquo;s current log handler.</p>

<p>A log handler might print the log record on the console, write it to a log file, forward it
to an external logging system, or otherwise process the log record.</p>
<div class="aside aside-see-also">
    <p class="aside-title">See also</p>
    <code><a href="Classes/ConsoleLogHandler.html">ConsoleLogHandler</a></code>

</div>

                          <a href="Protocols/LogHandler.html" class="slightly-smaller">See more</a>
                        </div>
                        <div class="declaration">
                          <h4>Declaration</h4>
                          <div class="language">
                            <p class="aside-title">Swift</p>
                            <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">protocol</span> <span class="kt">LogHandler</span></code></pre>

                          </div>
                        </div>
                      </section>
                    </div>
                  </li>
                  <li class="item">
                    <div>
                      <code>
                      <a name="/s:17PostgresClientKit0A16ValueConvertibleP"></a>
                      <a name="//apple_ref/swift/Protocol/PostgresValueConvertible" class="dashAnchor"></a>
                      <a class="token" href="#/s:17PostgresClientKit0A16ValueConvertibleP">PostgresValueConvertible</a>
                      </code>
                    </div>
                    <div class="height-container">
                      <div class="pointer-container"></div>
                      <section class="section">
                        <div class="pointer"></div>
                        <div class="abstract">
                          <p>A type whose instances can be the values of parameters in executing a <code><a href="Classes/Statement.html">Statement</a></code>.</p>

<p>The following types conform to <code>PostgresValueConvertible</code>:</p>

<ul>
<li><code>Bool</code></li>
<li><code>Decimal</code></li>
<li><code>Double</code></li>
<li><code>Int</code></li>
<li><code><a href="Structs/PostgresByteA.html">PostgresByteA</a></code></li>
<li><code><a href="Structs/PostgresDate.html">PostgresDate</a></code></li>
<li><code><a href="Structs/PostgresTime.html">PostgresTime</a></code></li>
<li><code><a href="Structs/PostgresTimeWithTimeZone.html">PostgresTimeWithTimeZone</a></code></li>
<li><code><a href="Structs/PostgresTimestamp.html">PostgresTimestamp</a></code></li>
<li><code><a href="Structs/PostgresTimestampWithTimeZone.html">PostgresTimestampWithTimeZone</a></code></li>
<li><code><a href="Structs/PostgresValue.html">PostgresValue</a></code></li>
<li><code>String</code></li>
</ul>

                          <a href="Protocols/PostgresValueConvertible.html" class="slightly-smaller">See more</a>
                        </div>
                        <div class="declaration">
                          <h4>Declaration</h4>
                          <div class="language">
                            <p class="aside-title">Swift</p>
                            <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">protocol</span> <span class="kt">PostgresValueConvertible</span></code></pre>

                          </div>
                        </div>
                      </section>
                    </div>
                  </li>
                </ul>
              </div>
            </section>
          </section>
        </article>
      </div>
      <div class="nav-wrapper">
        <nav class="nav-bottom">
          <ul class="nav-groups">
            <li class="nav-group-name">
              <a href="Classes.html">Classes</a>
              <ul class="nav-group-tasks">
                <li class="nav-group-task">
                  <a href="Classes/Connection.html">Connection</a>
                </li>
                <li class="nav-group-task">
                  <a href="Classes/ConnectionPool.html">ConnectionPool</a>
                </li>
                <li class="nav-group-task">
                  <a href="Classes/ConsoleLogHandler.html">ConsoleLogHandler</a>
                </li>
                <li class="nav-group-task">
                  <a href="Classes/Cursor.html">Cursor</a>
                </li>
                <li class="nav-group-task">
                  <a href="Classes/Logger.html">Logger</a>
                </li>
                <li class="nav-group-task">
                  <a href="Classes/Statement.html">Statement</a>
                </li>
              </ul>
            </li>
            <li class="nav-group-name">
              <a href="Enums.html">Enumerations</a>
              <ul class="nav-group-tasks">
                <li class="nav-group-task">
                  <a href="Enums/Credential.html">Credential</a>
                </li>
                <li class="nav-group-task">
                  <a href="Enums/LogLevel.html">LogLevel</a>
                </li>
                <li class="nav-group-task">
                  <a href="Enums/PostgresError.html">PostgresError</a>
                </li>
              </ul>
            </li>
            <li class="nav-group-name">
              <a href="Extensions.html">Extensions</a>
              <ul class="nav-group-tasks">
                <li class="nav-group-task">
                  <a href="Extensions/Bool.html">Bool</a>
                </li>
                <li class="nav-group-task">
                  <a href="Extensions/Date.html">Date</a>
                </li>
                <li class="nav-group-task">
                  <a href="Extensions/Decimal.html">Decimal</a>
                </li>
                <li class="nav-group-task">
                  <a href="Extensions/Double.html">Double</a>
                </li>
                <li class="nav-group-task">
                  <a href="Extensions/Int.html">Int</a>
                </li>
                <li class="nav-group-task">
                  <a href="Extensions/Optional.html">Optional</a>
                </li>
                <li class="nav-group-task">
                  <a href="Extensions/String.html">String</a>
                </li>
              </ul>
            </li>
            <li class="nav-group-name">
              <a href="Protocols.html">Protocols</a>
              <ul class="nav-group-tasks">
                <li class="nav-group-task">
                  <a href="Protocols/ConnectionDelegate.html">ConnectionDelegate</a>
                </li>
                <li class="nav-group-task">
                  <a href="Protocols/LogHandler.html">LogHandler</a>
                </li>
                <li class="nav-group-task">
                  <a href="Protocols/PostgresValueConvertible.html">PostgresValueConvertible</a>
                </li>
              </ul>
            </li>
            <li class="nav-group-name">
              <a href="Structs.html">Structures</a>
              <ul class="nav-group-tasks">
                <li class="nav-group-task">
                  <a href="Structs/ColumnMetadata.html">ColumnMetadata</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/ConnectionConfiguration.html">ConnectionConfiguration</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/ConnectionPoolConfiguration.html">ConnectionPoolConfiguration</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/ConnectionPoolMetrics.html">ConnectionPoolMetrics</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/LogRecord.html">LogRecord</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/Notice.html">Notice</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/Postgres.html">Postgres</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/PostgresByteA.html">PostgresByteA</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/PostgresDate.html">PostgresDate</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/PostgresTime.html">PostgresTime</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/PostgresTimeWithTimeZone.html">PostgresTimeWithTimeZone</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/PostgresTimestamp.html">PostgresTimestamp</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/PostgresTimestampWithTimeZone.html">PostgresTimestampWithTimeZone</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/PostgresValue.html">PostgresValue</a>
                </li>
                <li class="nav-group-task">
                  <a href="Structs/Row.html">Row</a>
                </li>
              </ul>
            </li>
          </ul>
        </nav>
      </div>
      <div class="footer-wrapper">
        <section id="footer">
          <p>Copyright 2019 David Pitfield and the PostgresClientKit contributors. Licensed under the Apache License, Version 2.0.</p>
          <p>Generated by <a class="link" href="https://github.com/realm/jazzy" target="_blank" rel="external">jazzy ♪♫ v0.13.6</a>, a <a class="link" href="https://realm.io" target="_blank" rel="external">Realm</a> project.</p>
        </section>
      </div>
    </div>
  </body>
</div>
</html>
